<%-- 
    Document   : addFlight
    Created on : Oct 27, 2011, 1:14:18 AM
    Author     : LeThuyLinh
--%>

<%@taglib uri="http://java.fckeditor.net" prefix="FCK"%>
<html>
    <head>
        <link rel="stylesheet" type="text/css" href="Style/style.css" />
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Add Flight Page</title>                 
        <link rel="stylesheet" href="development-bundle/themes/base/jquery.ui.all.css">
	<script src="development-bundle/jquery-1.6.2.js"></script>
	<script src="development-bundle/ui/jquery.ui.core.js"></script>
	<script src="development-bundle/ui/jquery.ui.widget.js"></script>
	<script src="development-bundle/ui/jquery.ui.datepicker.js"></script>        
        <script type="text/javascript" src="js/jquery.validate.js"></script>
        <script type="text/javascript" src="js/additional-methods.js"></script>
	<link rel="stylesheet" href="development-bundle/demos.css">
        <script type="text/javascript">
            $(function(){
                $("#addFlight").validate({
                    rules:{
                        txtName: {
                            required: true                            
                        },
                        txtDepartureCity: {
                            required: true
                        },
                        txtArrivalCity: {
                            required: true
                        }
                   }                    
                })
            
        });
        $(function() {
		var dates = $( "#from, #to" ).datepicker({
			defaultDate: "+1w",
			changeMonth: true,
			numberOfMonths: 3,
			onSelect: function( selectedDate ) {
				var option = this.id == "from" ? "minDate" : "maxDate",
					instance = $( this ).data( "datepicker" ),
					date = $.datepicker.parseDate(
						instance.settings.dateFormat ||
						$.datepicker._defaults.dateFormat,
						selectedDate, instance.settings );
				dates.not( this ).datepicker( "option", option, date );
			}
		});
	});
	</script>
    </head>
    <body>
	<div id="header">
            <jsp:include page="header.jsp"/>
	</div>
	<div id="wrapper">
            <jsp:include page="sidebar.jsp"/>
            <div id="content">
			<div class="search"><span>Search</span> <input type="text" /></div>
			<div class="bg">
                            <div class="column1">
                                <center><span style="font-size: 15px;color: #2a2b2b;width: 200px;font-style: italic;font-weight: bold;">Add Flight</span><hr width="200" style="color: #0000FF"></hr></center><br>
                                <form name="addFlight" action="addFlight" id="addFlight" enctype="multipart/form-data" method="post">
                                    <table cellspacing="10"  border="0" style="background-color: #eaeff2">                                    
                                    <tr>
                                        <td valign="top">Name: </td><td valign="top"><input type="text" name="txtName" size="50"/></td>
                                    </tr>                   
                                    <tr>
                                        <td valign="top"><label for="from">Departure Time: </label></td>
                                        <td><input type="text" id="from" name="from"/> </td>    
                                    </tr>
                                    <tr>
                                        <td valign="top"><label for="to">Arrival Time: </label></td>
                                        <td><input type="text" id="to" name="to"/></td>
                                    </tr>
                                    <tr>
                                        <td valign="top">Departure City: </td><td valign="top"><input type="text" name="txtDepartureCity" size="50"/></td>
                                    </tr>
                                    <tr>
                                        <td valign="top">Arrival City: </td><td valign="top"><input type="text" name="txtArrivalCity" size="50"/></td>
                                    </tr>
                                    <tr align="center">
                                        <td colspan="2" valign="top"><input type="submit" value="Add"/> ||| <input type="reset" value="Reset"/></td>
                                    </tr>                                        
                                </table>
                                    </form>
                            </div>
                            <div class="column2">
                                <jsp:include page="column2.jsp"/>
                            </div>               
                            
				
			</div>
		</div>
	</div>
	<div id="footer">
            <jsp:include page="footer.jsp"/>
	</div>
</body>
</html>
